package com.hsy.crm.web.utils;

import com.hsy.crm.web.domain.entity.BaseEntity;
import com.google.common.collect.Maps;
import com.hsy.crm.web.domain.entity.BaseEntity;

import java.util.Map;

public class Mapx {

    private Map<String,Object> map = Maps.newHashMap();

    public void set(String key,Object value){
        map.put(key,value);
    }

    public Map<String,Object> map(){
        return map;
    }

    public static Mapx create(){
        return new Mapx();
    }

    public static Mapx create(BaseEntity entity){
        Mapx mapx = new Mapx();
        mapx.set("customerId",entity.getCustomerId());
        return mapx;
    }

}
